/*
 * @Author: zhumeng@sensorsdata.cn
 * @Date: 2024-04-03 17:41:25
 * @LastEditTime: 2024-04-03 20:36:02
 * @Description:
 */
import {
  Modal,
  ModalContent,
  ModalHeader,
  ModalBody,
  ModalFooter,
  Button,
  useDisclosure,
  Input
} from '@nextui-org/react'

export default function Recorder() {
  const { isOpen, onOpen, onOpenChange } = useDisclosure()

  return (
    <>
      <Button onPress={onOpen} color="primary" size="sm">
        更新资产
      </Button>
      <Modal
        backdrop="blur"
        isOpen={isOpen}
        onOpenChange={onOpenChange}
        placement="top-center"
        size="5xl"
      >
        <ModalContent>
          {(onClose) => (
            <>
              <ModalHeader className="flex flex-col gap-1">
                更新资产
              </ModalHeader>
              <ModalBody>
                <Input
                  endContent={
                    <img
                      src="/img/wechat.png"
                      width={16}
                      height={16}
                      className="max-[24px]"
                    />
                  }
                  label="支付宝"
                  // variant="bordered"
                />
              </ModalBody>
              <ModalFooter>
                <Button color="danger" variant="flat" onPress={onClose}>
                  取消
                </Button>
                <Button color="primary" onPress={onClose}>
                  更新
                </Button>
              </ModalFooter>
            </>
          )}
        </ModalContent>
      </Modal>
    </>
  )
}
